Class ClassScanner

Summary

Fully Qualified Name: Laminas\Code\Scanner\ClassScanner
Implements: ScannerInterface

Description

Methods

Name Description Defined By
__construct() ClassScanner
__toString() ClassScanner
export() ClassScanner
getAnnotations() Get annotations ClassScanner
getConstant() Return a single constant by given name or index of info ClassScanner
getConstantNames() Return a list of constant names ClassScanner
getConstants() Return a list of constants ClassScanner
getDocBlock() Return documentation block ClassScanner
getDocComment() Return documentation comment ClassScanner
getInterfaces() Return a list of interface names ClassScanner
getLineEnd() Return number of last line ClassScanner
getLineStart() Return number of first line ClassScanner
getMethod() Return a single method by given name or index of info ClassScanner
getMethodNames() Return a list of method names ClassScanner
getMethods() Return a list of methods ClassScanner
getName() Return a name of class ClassScanner
getParentClass() Return a name of parent class ClassScanner
getProperties() Return a list of properties ClassScanner
getProperty() Return a single property by given name or index of info ClassScanner
getPropertyNames() Return a list of property names ClassScanner
getShortName() Return short name of class ClassScanner
getTraitAliases() Retrieve a list of aliased traits used by the class. ClassScanner
getTraitNames() Retrieve a list of trait names used by this class. ClassScanner
getTraits() Retrieve any traits used by the class. ClassScanner
hasConstant() Verify if class has constant ClassScanner
hasMethod() Verify if class has method by given name ClassScanner
hasParentClass() Verify if class has parent ClassScanner
hasProperty() Verify if class has property ClassScanner
isAbstract() Verify if class is an abstract class ClassScanner
isFinal() Verify if class is final ClassScanner
isInstantiable() Verify if class is instantiable ClassScanner
isInterface() Verify if class is an interface ClassScanner
isTrait() Verify if class is a trait ClassScanner

Method Details

__construct()

Parameter Name Type Description
$classTokens array
$nameInformation \NameInformation|null

Returns: \ClassScanner

__toString()

Returns: void

export()

Returns: void

getAnnotations()

Get annotations

Parameter Name Type Description
$annotationManager \Annotation\AnnotationManager

Returns: \Annotation\AnnotationCollection

getConstant()

Return a single constant by given name or index of info

Parameter Name Type Description
$constantNameOrInfoIndex string|int

Returns: bool|\ConstantScanner

getConstantNames()

Return a list of constant names

Returns: array

getConstants()

Return a list of constants

Parameter Name Type Description
$namesOnly bool Set

Returns: array|\ConstantScanner[]

getDocBlock()

Return documentation block

Returns: bool|\DocBlockScanner

getDocComment()

Return documentation comment

Returns: null|string

getInterfaces()

Return a list of interface names

Returns: array

getLineEnd()

Return number of last line

Returns: int|null

getLineStart()

Return number of first line

Returns: int|null

getMethod()

Return a single method by given name or index of info

Parameter Name Type Description
$methodNameOrInfoIndex string|int

Returns: \MethodScanner

getMethodNames()

Return a list of method names

Returns: array

getMethods()

Return a list of methods

Returns: \MethodScanner[]

getName()

Return a name of class

Returns: null|string

getParentClass()

Return a name of parent class

Returns: null|string

getProperties()

Return a list of properties

Returns: \PropertyScanner[]

getProperty()

Return a single property by given name or index of info

Parameter Name Type Description
$propertyNameOrInfoIndex string|int

Returns: bool|\PropertyScanner

getPropertyNames()

Return a list of property names

Returns: array

getShortName()

Return short name of class

Returns: null|string

getTraitAliases()

Retrieve a list of aliased traits used by the class.

Returns: array

getTraitNames()

Retrieve a list of trait names used by this class.

Returns: array

getTraits()

Retrieve any traits used by the class.

Returns: \ClassScanner[]

hasConstant()

Verify if class has constant

Parameter Name Type Description
$name string

Returns: bool

hasMethod()

Verify if class has method by given name

Parameter Name Type Description
$name string

Returns: bool

hasParentClass()

Verify if class has parent

Returns: bool

hasProperty()

Verify if class has property

Parameter Name Type Description
$name string

Returns: bool

isAbstract()

Verify if class is an abstract class

Returns: bool

isFinal()

Verify if class is final

Returns: bool

isInstantiable()

Verify if class is instantiable

Returns: bool

isInterface()

Verify if class is an interface

Returns: bool

isTrait()

Verify if class is a trait

Returns: bool

Top